//
//  UpdateDetial.swift
//  DesignCode
//
//  Created by 刘文超 on 2020/5/8.
//  Copyright © 2020 刘文超. All rights reserved.
//

import SwiftUI

struct UpdateDetial: View {
    var model:updateModel = updateArray[0]
    
    
    var body: some View {
        
        List {
            VStack ( spacing: 8){
                Image(model.pic)
                    .resizable()
                    .aspectRatio(contentMode: .fit)
                    .frame( maxWidth: .infinity)
                
                Text(model.content)
                    .font(.system(size: 14, weight: .medium))
                    .foregroundColor(Color(#colorLiteral(red: 0.6000000238, green: 0.6000000238, blue: 0.6000000238, alpha: 1)))
                    .frame( maxWidth: .infinity, alignment: .leading)
            }
           
        }
         .navigationBarTitle(Text(model.title))
    }
}

struct UpdateDetial_Previews: PreviewProvider {
    static var previews: some View {
        UpdateDetial()
    }
}
